package com.ybl.stepview_yw;

import android.content.Intent;
import android.support.v7.app.AppCompatActivity;
import android.os.Bundle;
import android.view.View;
import android.widget.Button;

public class MainActivity extends AppCompatActivity implements View.OnClickListener {

    @Override
    protected void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setContentView(R.layout.activity_main);
        Button btnVertical = (Button) findViewById(R.id.btn_vertical);
        Button btnHor = (Button) findViewById(R.id.btn_hor);

        btnVertical.setOnClickListener(this);
        btnHor.setOnClickListener(this);
    }


    @Override
    public void onClick(View v) {
        switch (v.getId()) {
            case R.id.btn_vertical:
                startActivity(new Intent(this, VerticalStepDemo.class));
                break;
            case R.id.btn_hor:
                startActivity(new Intent(this, HorizontalStepDemo.class));
                break;
        }
    }
}
